package com.springcloud.ribbondemo.config


import com.netflix.loadbalancer.IRule
import com.netflix.loadbalancer.RandomRule
import com.netflix.loadbalancer.RoundRobinRule
import com.netflix.loadbalancer.WeightedResponseTimeRule
import org.springframework.context.annotation.Bean
import org.springframework.context.annotation.Configuration

class RibbonP2Config {

    /*
    轮询策略:逐个循环调用
     */
    @Bean
    IRule rule()
    {
        new RoundRobinRule()
    }

}
